home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 26
/
Cream of the Crop 26.iso
/
program
/
qlib205.zip
/
QLIB.ZIP
/
SRC
/
QLIB
/
INT.ASM
< prev
next >
Wrap
Assembly Source File
|
1996-12-17
|
876b
|
60 lines
include qlib.inc
include dos.inc
.code
getint proc,v:byte
pushad
mov ax,204h
mov bl,v
int 31h
mov [esp+7*4],cx ;ax
mov [esp+5*4],edx ;edx
popad
ret
getint endp ;ax:edx = vector
setint proc,v:byte,s:word,off:dword
pushad
mov ax,205h
mov bl,v
mov cx,s
mov edx,off
int 31h
jc notgood
popad
xor eax,eax
ret
notgood:
popad
mov eax,ERROR
ret
setint endp ;ax=0
getrmint proc uses ebx,v:byte
movzx ebx,v
shl ebx,2
xor edx,edx
xor eax,eax
cli
mov dx,[ebx] ;offset ;FIXED V1.2 : was using eax after I loaded it
mov ax,[ebx+2] ;seg
sti
ret
getrmint endp ;ax:dx = vektor
setrmint proc uses ebx,v:byte,s:word,off:word
movzx eax,v
shl eax,2 ;*4
cli
mov bx,off
mov [eax],bx
mov bx,s
mov [eax+2],bx
sti
xor eax,eax
ret
setrmint endp
end